﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace MyVoteMVC.Domain
{
    /// <summary>
    /// 抽奖名单
    /// </summary>
    public class VT_Lotteries
    {
    /// <summary>
    /// pk
    /// </summary>
        public string Lottery_ID { get; set; }

        /// <summary>
        /// 等级
        /// </summary>
        public int? Lottery_Level { get; set; }

        /// <summary>
        /// 抽奖类型
        /// </summary>
        public int? Lottery_TypeValue{ get; set; }
        public LotteryType Lottery_Type
        {
            get
            {
                return (LotteryType)Lottery_TypeValue;
            }
            set
            {
                Lottery_TypeValue = (int)value;
            }
        }

        /// <summary>
        /// 票据
        /// </summary>
        public string Ticket_ID { get; set; }

        /// <summary>
        /// 中奖时间
        /// </summary>
        public DateTime? Created_Date { get; set; }

        public virtual VT_Tickets Ticket { get; set; }


        /*冗余字段*/
        /// <summary>
        /// FK 所属活动ID
        /// </summary>
        public string Activity_ID { get; set; }
        /// <summary>
        /// 用户邮箱地址(唯一)
        /// </summary>
        public string User_Email { get; set; }
    }

    /// <summary>
    /// 投票类型
    /// </summary>
    public enum LotteryType
    {
        Ramdom = 0,//随机
        BigDogDog = 1//最后大抽奖
    }
}
